package com.moonciki.artadmin.core.constant;

/**
 * 全局常量
 */
public class GlobalConstant {

    public final static String generator_db_key = "demo";

    public static class Base{
        /** 全局项目中文名称 **/
        public final static String project_name_zh = "管理demo";
        /** 包名 **/
        public final static String base_package = "com.moonciki.artadmin";

        public final static String common_package = base_package + ".core";

        public final static String base_web_package = base_package + ".web";

    }

    /** 常用 http code **/
    public static class HttpCode{
        /** 成功 **/
        public static final int success = 200;
        /** 重定向 **/
        public static final int redirect = 302;
        /** 没有登录 **/
        public static final int no_login = 401;
        /** 没有权限 **/
        public static final int no_permission = 403;
        /** 404 **/
        public static final int no_found = 404;
        /** 同一用户多次登录被踢出 **/
        public static final int kick_out = 409;
        /** 系统异常 **/
        public static final int sys_error = 500;

    }

    /**
     * redis key
     */
    public class RedisKey {

        /** 全局 redis key 前缀 **/
        public final static String base = "moonciki:demo:";

        /** cache **/
        public final static String spring_cache = base + "spring_cache:";

    }

    /**
     * 默认页数
     */
    public final static int default_page_size = 30;

}
